package jsyf.oa.entity.system;

import com.alibaba.fastjson.JSONObject;
import jsyf.oa.entity.attach.AttachModuleEntity;
import jsyf.oa.entity.attach.AttachmentEntity;
import jsyf.oa.ientity.BaseEntity;

import javax.persistence.*;
import java.io.Serializable;
import java.util.Date;
import java.util.List;


@Entity
@Table(name = "T_SYS_USER", schema = "oa", catalog = "")
public class UserEntity extends BaseEntity implements Serializable {
    private String fileNo;
    private String name;
    private Integer sex;
    private String tel;
    private String pwd;
    private String birthday;
    private String address;
    private String graduate;
    private String nativePlace;
    private String card;
    private String education;
    private String professional;
    private String roleId;
    private String createUserId;
    private String updateUserId;
    private String entryDate;
    private String leaveDate;
    private Integer workContract;
    private String workContractStartTime;
    private String workContractEndTime;
    private Integer jobState;
    private String parentId;
    private String email;
    private String bank;
    private String wegeCard;
    private Integer computerStart;
    private Integer carStart;
    private String carBrand;
    private String carCard;
    private String oilCard;
    private String carModel;
    private String allowCard;
    private String guardCard;
    private String tool;
    private String pos;
    private String workClothes;
    private String wxId;
    private String wxAvatar;
    private List<User2RoleEntity> userRoles;
    //档案不全字段
    private Integer archivaType;

    //附件信息
    private String nameAttachName;
    private String nameAttachUrl;
    private String cardAttachName;
    private String cardAttachUrl;
    private String educationAttachName;
    private String educationAttachUrl;
    private String carAttachName;
    private String carAttachUrl;
    private String allowAttachName;
    private String allowAttachUrl;
    private String toolAttachName;
    private String toolAttachUrl;
    private String entrtyInforAttachName;
    private String entrtyInforAttachUrl;
    private String entrtyAgreeAttachName;
    private String entrtyAgreeAttachUrl;
    private String contractAttachName;
    private String contractAttachUrl;
    private String secrecyAttachName;
    private String secrecyAttachUrl;
    private String spell;
    private String imagerUrl;


    private String permanent;//户籍所在地
    private String diplomaName;//学位证书
    private String diplomaUrl;//学位证书url
    private String telOwner;//手机号所有权
    private String salesClothes;//销售工服数量
    private String salesClothesTime;//销售工服创建时间
    private String servicesClothes;//服务工服数量
    private String servicesClothesTime;//服务工服创建时间
    private String carMatch;//配车用途
    private String carOwner;//配车所有权
    private String computerOwner;//电脑所有权

    private String residence;//常住地址
    private String longitude;//经度
    private String latitude;//纬度


    public String getSecrecyAttachName() {
        return secrecyAttachName;
    }

    public void setSecrecyAttachName(String secrecyAttachName) {
        this.secrecyAttachName = secrecyAttachName;
    }

    public String getSecrecyAttachUrl() {
        return secrecyAttachUrl;
    }

    public void setSecrecyAttachUrl(String secrecyAttachUrl) {
        this.secrecyAttachUrl = secrecyAttachUrl;
    }

    public String getNameAttachName() {
        return nameAttachName;
    }

    public void setNameAttachName(String nameAttachName) {
        this.nameAttachName = nameAttachName;
    }

    public String getNameAttachUrl() {
        return nameAttachUrl;
    }

    public void setNameAttachUrl(String nameAttachUrl) {
        this.nameAttachUrl = nameAttachUrl;
    }

    public String getCardAttachName() {
        return cardAttachName;
    }

    public void setCardAttachName(String cardAttachName) {
        this.cardAttachName = cardAttachName;
    }

    public String getCardAttachUrl() {
        return cardAttachUrl;
    }

    public void setCardAttachUrl(String cardAttachUrl) {
        this.cardAttachUrl = cardAttachUrl;
    }

    public String getEducationAttachName() {
        return educationAttachName;
    }

    public void setEducationAttachName(String educationAttachName) {
        this.educationAttachName = educationAttachName;
    }

    public String getEducationAttachUrl() {
        return educationAttachUrl;
    }

    public void setEducationAttachUrl(String educationAttachUrl) {
        this.educationAttachUrl = educationAttachUrl;
    }

    public String getCarAttachName() {
        return carAttachName;
    }

    public void setCarAttachName(String carAttachName) {
        this.carAttachName = carAttachName;
    }

    public String getCarAttachUrl() {
        return carAttachUrl;
    }

    public void setCarAttachUrl(String carAttachUrl) {
        this.carAttachUrl = carAttachUrl;
    }

    public String getAllowAttachName() {
        return allowAttachName;
    }

    public void setAllowAttachName(String allowAttachName) {
        this.allowAttachName = allowAttachName;
    }

    public String getAllowAttachUrl() {
        return allowAttachUrl;
    }

    public void setAllowAttachUrl(String allowAttachUrl) {
        this.allowAttachUrl = allowAttachUrl;
    }

    public String getToolAttachName() {
        return toolAttachName;
    }

    public void setToolAttachName(String toolAttachName) {
        this.toolAttachName = toolAttachName;
    }

    public String getToolAttachUrl() {
        return toolAttachUrl;
    }

    public void setToolAttachUrl(String toolAttachUrl) {
        this.toolAttachUrl = toolAttachUrl;
    }

    public String getEntrtyInforAttachName() {
        return entrtyInforAttachName;
    }

    public void setEntrtyInforAttachName(String entrtyInforAttachName) {
        this.entrtyInforAttachName = entrtyInforAttachName;
    }

    public String getEntrtyInforAttachUrl() {
        return entrtyInforAttachUrl;
    }

    public void setEntrtyInforAttachUrl(String entrtyInforAttachUrl) {
        this.entrtyInforAttachUrl = entrtyInforAttachUrl;
    }

    public String getEntrtyAgreeAttachName() {
        return entrtyAgreeAttachName;
    }

    public void setEntrtyAgreeAttachName(String entrtyAgreeAttachName) {
        this.entrtyAgreeAttachName = entrtyAgreeAttachName;
    }

    public String getEntrtyAgreeAttachUrl() {
        return entrtyAgreeAttachUrl;
    }

    public void setEntrtyAgreeAttachUrl(String entrtyAgreeAttachUrl) {
        this.entrtyAgreeAttachUrl = entrtyAgreeAttachUrl;
    }

    public String getContractAttachName() {
        return contractAttachName;
    }

    public void setContractAttachName(String contractAttachName) {
        this.contractAttachName = contractAttachName;
    }

    public String getContractAttachUrl() {
        return contractAttachUrl;
    }

    public void setContractAttachUrl(String contractAttachUrl) {
        this.contractAttachUrl = contractAttachUrl;
    }

    public String getFileNo() {
        return fileNo;
    }

    public void setFileNo(String fileNo) {
        this.fileNo = fileNo;
    }

    public String getName() {
        return name;
    }

    public void setName(String name) {
        this.name = name;
    }

    public Integer getSex() {
        return sex;
    }

    public void setSex(Integer sex) {
        this.sex = sex;
    }


    public String getPwd() {
        return pwd;
    }

    public void setPwd(String pwd) {
        this.pwd = pwd;
    }

    public String getBirthday() {
        return birthday;
    }

    public void setBirthday(String birthday) {
        this.birthday = birthday;
    }

    public String getAddress() {
        return address;
    }

    public void setAddress(String address) {
        this.address = address;
    }

    public String getGraduate() {
        return graduate;
    }

    public void setGraduate(String graduate) {
        this.graduate = graduate;
    }

    public String getNativePlace() {
        return nativePlace;
    }

    public void setNativePlace(String nativePlace) {
        this.nativePlace = nativePlace;
    }

    public String getCard() {
        return card;
    }

    public void setCard(String card) {
        this.card = card;
    }

    public String getEducation() {
        return education;
    }

    public void setEducation(String education) {
        this.education = education;
    }

    public String getProfessional() {
        return professional;
    }

    public void setProfessional(String professional) {
        this.professional = professional;
    }

    public String getRoleId() {
        return roleId;
    }

    public void setRoleId(String roleId) {
        this.roleId = roleId;
    }

    public String getCreateUserId() {
        return createUserId;
    }

    public void setCreateUserId(String createUserId) {
        this.createUserId = createUserId;
    }

    public String getUpdateUserId() {
        return updateUserId;
    }

    public void setUpdateUserId(String updateUserId) {
        this.updateUserId = updateUserId;
    }

    public String getEntryDate() {
        return entryDate;
    }

    public void setEntryDate(String entryDate) {
        this.entryDate = entryDate;
    }

    public String getLeaveDate() {
        return leaveDate;
    }

    public void setLeaveDate(String leaveDate) {
        this.leaveDate = leaveDate;
    }

    public Integer getJobState() {
        return jobState;
    }

    public void setJobState(Integer jobState) {
        this.jobState = jobState;
    }

    public String getParentId() {
        return parentId;
    }

    public void setParentId(String parentId) {
        this.parentId = parentId;
    }

    public String getEmail() {
        return email;
    }

    public void setEmail(String email) {
        this.email = email;
    }

    public String getBank() {
        return bank;
    }

    public void setBank(String bank) {
        this.bank = bank;
    }

    public String getWegeCard() {
        return wegeCard;
    }

    public void setWegeCard(String wegeCard) {
        this.wegeCard = wegeCard;
    }

    public String getTel() {
        return tel;
    }

    public void setTel(String tel) {
        this.tel = tel;
    }

    public Integer getComputerStart() {
        return computerStart;
    }

    public void setComputerStart(Integer computerStart) {
        this.computerStart = computerStart;
    }

    public Integer getCarStart() {
        return carStart;
    }

    public void setCarStart(Integer carStart) {
        this.carStart = carStart;
    }

    public String getCarBrand() {
        return carBrand;
    }

    public void setCarBrand(String carBrand) {
        this.carBrand = carBrand;
    }

    public String getCarCard() {
        return carCard;
    }

    public void setCarCard(String carCard) {
        this.carCard = carCard;
    }

    public String getOilCard() {
        return oilCard;
    }

    public void setOilCard(String oilCard) {
        this.oilCard = oilCard;
    }

    public String getCarModel() {
        return carModel;
    }

    public void setCarModel(String carModel) {
        this.carModel = carModel;
    }

    public String getAllowCard() {
        return allowCard;
    }

    public void setAllowCard(String allowCard) {
        this.allowCard = allowCard;
    }

    public String getGuardCard() {
        return guardCard;
    }

    public void setGuardCard(String guardCard) {
        this.guardCard = guardCard;
    }

    public String getTool() {
        return tool;
    }

    public void setTool(String tool) {
        this.tool = tool;
    }

    public String getPos() {
        return pos;
    }

    public void setPos(String pos) {
        this.pos = pos;
    }

    public String getWorkClothes() {
        return workClothes;
    }

    public void setWorkClothes(String workClothes) {
        this.workClothes = workClothes;
    }


    public List<User2RoleEntity> getUserRoles() {
        return userRoles;
    }

    public void setUserRoles(List<User2RoleEntity> userRoles) {
        this.userRoles = userRoles;
    }

    public String getWxId() {
        return wxId;
    }

    public void setWxId(String wxId) {
        this.wxId = wxId;
    }

    public String getWxAvatar() {
        return wxAvatar;
    }

    public void setWxAvatar(String wxAvatar) {
        this.wxAvatar = wxAvatar;
    }


    public Integer getArchivaType() {
        return archivaType;
    }

    public void setArchivaType(Integer archivaType) {
        this.archivaType = archivaType;
    }

    public Integer getWorkContract() {
        return workContract;
    }

    public void setWorkContract(Integer workContract) {
        this.workContract = workContract;
    }

    public String getWorkContractStartTime() {
        return workContractStartTime;
    }

    public void setWorkContractStartTime(String workContractStartTime) {
        this.workContractStartTime = workContractStartTime;
    }

    public String getWorkContractEndTime() {
        return workContractEndTime;
    }

    public void setWorkContractEndTime(String workContractEndTime) {
        this.workContractEndTime = workContractEndTime;
    }

    public String getSpell() {
        return spell;
    }

    public void setSpell(String spell) {
        this.spell = spell;
    }

    public String getImagerUrl() {
        return imagerUrl;
    }

    public void setImagerUrl(String imagerUrl) {
        this.imagerUrl = imagerUrl;
    }


    public String getPermanent() {
        return permanent;
    }

    public void setPermanent(String permanent) {
        this.permanent = permanent;
    }

    public String getDiplomaName() {
        return diplomaName;
    }

    public void setDiplomaName(String diplomaName) {
        this.diplomaName = diplomaName;
    }

    public String getDiplomaUrl() {
        return diplomaUrl;
    }

    public void setDiplomaUrl(String diplomaUrl) {
        this.diplomaUrl = diplomaUrl;
    }

    public String getComputerOwner() {
        return computerOwner;
    }

    public void setComputerOwner(String computerOwner) {
        this.computerOwner = computerOwner;
    }

    public String getTelOwner() {
        return telOwner;
    }

    public void setTelOwner(String telOwner) {
        this.telOwner = telOwner;
    }

    public String getSalesClothes() {
        return salesClothes;
    }

    public void setSalesClothes(String salesClothes) {
        this.salesClothes = salesClothes;
    }

    public String getSalesClothesTime() {
        return salesClothesTime;
    }

    public void setSalesClothesTime(String salesClothesTime) {
        this.salesClothesTime = salesClothesTime;
    }

    public String getServicesClothes() {
        return servicesClothes;
    }

    public void setServicesClothes(String servicesClothes) {
        this.servicesClothes = servicesClothes;
    }

    public String getServicesClothesTime() {
        return servicesClothesTime;
    }

    public void setServicesClothesTime(String servicesClothesTime) {
        this.servicesClothesTime = servicesClothesTime;
    }

    public String getCarMatch() {
        return carMatch;
    }

    public void setCarMatch(String carMatch) {
        this.carMatch = carMatch;
    }

    public String getCarOwner() {
        return carOwner;
    }

    public void setCarOwner(String carOwner) {
        this.carOwner = carOwner;
    }

    public String getResidence() {
        return residence;
    }

    public void setResidence(String residence) {
        this.residence = residence;
    }

    public String getLongitude() {
        return longitude;
    }

    public void setLongitude(String longitude) {
        this.longitude = longitude;
    }

    public String getLatitude() {
        return latitude;
    }

    public void setLatitude(String latitude) {
        this.latitude = latitude;
    }

    public JSONObject getJSONObject() {
        JSONObject obj = new JSONObject();
        obj.put("ID", this.getId());
        obj.put("FILE_NO", this.getFileNo());
        obj.put("NAME", this.getName());
        obj.put("SEX", this.getSex());
        obj.put("TEL", this.getTel());
        obj.put("PWD", this.getPwd());
        obj.put("BIRTHDAY", this.getBirthday());
        obj.put("ADDRESS", this.getAddress());
        obj.put("GRADUATE", this.getGraduate());
        obj.put("NATIVE_PLACE", this.getNativePlace());
        obj.put("CARD", this.getCard());
        obj.put("EDUCATION", this.getEducation());
        obj.put("PROFESSIONAL", this.getProfessional());
        obj.put("ROLE_ID", this.getRoleId());
        obj.put("CREATE_USER_ID", this.getCreateUserId());
        obj.put("CREATE_TIME", this.getCreateTime());
        obj.put("UPDATE_USER_ID", this.getUpdateUserId());
        obj.put("UPDATE_TIME", this.getUpdateTime());
        obj.put("DEL_FLAG", this.getDelFlag());
        obj.put("ENTRY_DATE", this.getEntryDate());
        obj.put("WORK_CONTRACT", this.getWorkContract());
        obj.put("WORK_CONTRACT_START_TIME", this.getWorkContractStartTime());
        obj.put("WORK_CONTRACT_END_TIME", this.getWorkContractEndTime());
        obj.put("JOB_STATE", this.getJobState());
        obj.put("PARENT_ID", this.getParentId());
        obj.put("EMAIL", this.getEmail());
        obj.put("BANK", this.getBank());
        obj.put("WEGE_CARD", this.getWegeCard());
        obj.put("COMPUTER_START", this.getComputerStart());
        obj.put("CAR_START", this.getCarStart());
        obj.put("CAR_BRAND", this.getCarBrand());
        obj.put("CAR_CARD", this.getCarCard());
        obj.put("OIL_CARD", this.getOilCard());
        obj.put("CAR_MODEL", this.getCarModel());
        obj.put("ALLOW_CARD", this.getAllowCard());
        obj.put("GUARD_CARD", this.getGuardCard());
        obj.put("TOOL", this.getTool());
        obj.put("POS", getPos());
        obj.put("WORK_CLOTHES", getWorkClothes());
        obj.put("NAME_ATTACH_NAME", getNameAttachName());
        obj.put("NAME_ATTACH_URL", getNameAttachUrl());
        obj.put("CARD_ATTACH_NAME", getCardAttachName());
        obj.put("CARD_ATTACH_URL", getCardAttachUrl());
        obj.put("EDUCATION_ATTACH_NAME", getEducationAttachName());
        obj.put("EDUCATION_ATTACH_URL", getEducationAttachUrl());
        obj.put("CAR_ATTACH_NAME", getCarAttachName());
        obj.put("CAR_ATTACH_URL", getCarAttachUrl());
        obj.put("ALLOW_ATTACH_NAME", getAllowAttachName());
        obj.put("ALLOW_ATTACH_URL", getAllowAttachUrl());
        obj.put("TOOL_ATTACH_NAME", getToolAttachName());
        obj.put("TOOL_ATTACH_URL", getToolAttachUrl());
        obj.put("ENTRTY_INFOR_ATTACH_NAME", getEntrtyInforAttachName());
        obj.put("ENTRTY_INFOR_ATTACH_URL", getEntrtyInforAttachUrl());
        obj.put("ENTRTY_AGREE_ATTACH_NAME", getEntrtyAgreeAttachName());
        obj.put("ENTRTY_AGREE_ATTACH_URL", getEntrtyAgreeAttachUrl());
        obj.put("CONTRACT_ATTACH_NAME", getContractAttachName());
        obj.put("CONTRACT_ATTACH_URL", getContractAttachUrl());
        obj.put("SECRECY_ATTACH_NAME", getSecrecyAttachName());
        obj.put("SECRECY_ATTACH_URL", getSecrecyAttachUrl());
        obj.put("ARCHIVA_TYPE", getArchivaType());
        obj.put("SPELL", getSpell());
        obj.put("IMAGER_URL", getImagerUrl());
        obj.put("PERMANENT", getPermanent());
        obj.put("DIPLOMA_NAME", getDiplomaName());
        obj.put("DIPLOMA_URL", getDiplomaUrl());
        obj.put("TEL_OWNER", getTelOwner());
        obj.put("SALES_CLOTHES", getSalesClothes());
        obj.put("SALES_CLOTHES_TIME", getSalesClothesTime());
        obj.put("SERVICES_CLOTHES", getServicesClothes());
        obj.put("SERVICES_CLOTHES_TIME", getServicesClothesTime());
        obj.put("CAR_MATCH", getCarMatch());
        obj.put("CAR_OWNER", getCarOwner());
        obj.put("COMPUTER_OWNER", getComputerOwner());
        obj.put("RESIDENCE", getResidence());
        obj.put("LONGITUDE", getLongitude());
        obj.put("LATITUDE", getLatitude());
        obj.put("WX_ID",getWxId());
        obj.put("WX_AVATAR", getWxAvatar());
        return obj;
    }

    public JSONObject getJSONObjectId() {
        JSONObject obj = new JSONObject();
        obj.put("ID", this.getId());
        return obj;
    }

    @Override
    public String getTableName() {
        return "T_SYS_USER";
    }

    @Override
    public String getViewName() {
        return "V_SYS_USER";
    }

    @Override
    public JSONObject getJSONColumns() {
        JSONObject obj = new JSONObject();
        obj.put("ID", "id");
        obj.put("FILE_NO", "fileNo");
        obj.put("NAME", "name");
        obj.put("SEX", "sex");
        obj.put("TEL", "tel");
        obj.put("PWD", "pwd");
        obj.put("BIRTHDAY", "birthday");
        obj.put("ADDRESS", "address");
        obj.put("GRADUATE", "graduate");
        obj.put("NATIVE_PLACE", "nativePlace");
        obj.put("CARD", "card");
        obj.put("EDUCATION", "education");
        obj.put("PROFESSIONAL", "professional");
        obj.put("ROLE_ID", "roleId");
        obj.put("CREATE_USER_ID", "createUserId");
        obj.put("UPDATE_USER_ID", "updateUserId");
        obj.put("DEL_FLAG", "delFlag");
        obj.put("ENTRY_DATE", "entryDate");
        obj.put("WORK_CONTRACT", "workContract");
        obj.put("WORK_CONTRACT_START_TIME", "workContractStartTime");
        obj.put("WORK_CONTRACT_END_TIME", "workContractEndTime");
        obj.put("JOB_STATE", "jobState");
        obj.put("PARENT_ID", "parentId");
        obj.put("EMAIL", "email");
        obj.put("BANK", "bank");
        obj.put("WEGE_CARD", "wegeCard");
        obj.put("COMPUTER_START", "computerStart");
        obj.put("CAR_START", "carStart");
        obj.put("CAR_BRAND", "carBrand");
        obj.put("CAR_CARD", "carCard");
        obj.put("OIL_CARD", "oilCard");
        obj.put("CAR_MODEL", "carModel");
        obj.put("ALLOW_CARD", "allowCard");
        obj.put("GUARD_CARD", "guardCard");
        obj.put("TOOL", "tool");
        obj.put("POS", "pos");
        obj.put("WORK_CLOTHES", "workClothes");
        obj.put("NAME_ATTACH_NAME", "nameAttachName");
        obj.put("NAME_ATTACH_URL", "nameAttachUrl");
        obj.put("CARD_ATTACH_NAME", "cardAttachName");
        obj.put("CARD_ATTACH_URL", "cardAttachUrl");
        obj.put("EDUCATION_ATTACH_NAME", "educationAttachName");
        obj.put("EDUCATION_ATTACH_URL", "educationAttachUrl");
        obj.put("CAR_ATTACH_NAME", "carAttachName");
        obj.put("CAR_ATTACH_URL", "carAttachUrl");
        obj.put("ALLOW_ATTACH_NAME", "allowAttachName");
        obj.put("ALLOW_ATTACH_URL", "allowAttachUrl");
        obj.put("TOOL_ATTACH_NAME", "toolAttachName");
        obj.put("TOOL_ATTACH_URL", "toolAttachUrl");
        obj.put("ENTRTY_INFOR_ATTACH_NAME", "entrtyInforAttachName");
        obj.put("ENTRTY_INFOR_ATTACH_URL", "entrtyInforAttachUrl");
        obj.put("ENTRTY_AGREE_ATTACH_NAME", "entrtyAgreeAttachName");
        obj.put("ENTRTY_AGREE_ATTACH_URL", "entrtyAgreeAttachUrl");
        obj.put("CONTRACT_ATTACH_NAME", "contractAttachName");
        obj.put("CONTRACT_ATTACH_URL", "contractAttachUrl");
        obj.put("SECRECY_ATTACH_NAME", "secrecyAttachName");
        obj.put("SECRECY_ATTACH_URL", "secrecyAttachUrl");
        obj.put("ARCHIVA_TYPE", "archivaType");
        obj.put("SPELL", "spell");
        obj.put("IMAGER_URL", "imagerUrl");
        obj.put("PERMANENT", "permanent");
        obj.put("DIPLOMA_NAME", "diplomaName");
        obj.put("DIPLOMA_URL", "diplomaUrl");
        obj.put("TEL_OWNER", "telOwner");
        obj.put("SALES_CLOTHES", "salesClothes");
        obj.put("SALES_CLOTHES_TIME", "salesClothesTime");
        obj.put("SERVICES_CLOTHES", "servicesClothes");
        obj.put("SERVICES_CLOTHES_TIME", "servicesClothesTime");
        obj.put("CAR_MATCH", "carMatch");
        obj.put("CAR_OWNER", "carOwner");
        obj.put("COMPUTER_OWNER", "computerOwner");
        obj.put("RESIDENCE", "residence");
        obj.put("LONGITUDE", "longitude");
        obj.put("LATITUDE", "latitude");
        obj.put("LATITUDE", "latitude");
        obj.put("WX_ID", "wxId");
        obj.put("WX_AVATAR", "wxAvatar");
        return obj;
    }

    @Override
    public boolean equals(Object o) {
        if (this == o) return true;
        if (o == null || getClass() != o.getClass()) return false;

        UserEntity that = (UserEntity) o;

        if (jobState != that.jobState) return false;
        if (id != null ? !id.equals(that.id) : that.id != null) return false;
        if (name != null ? !name.equals(that.name) : that.name != null) return false;
        if (tel != null ? !tel.equals(that.tel) : that.tel != null) return false;
        if (pwd != null ? !pwd.equals(that.pwd) : that.pwd != null) return false;
        if (roleId != null ? !roleId.equals(that.roleId) : that.roleId != null) return false;
        if (createUserId != null ? !createUserId.equals(that.createUserId) : that.createUserId != null) return false;
        if (createTime != null ? !createTime.equals(that.createTime) : that.createTime != null) return false;
        if (updateUserId != null ? !updateUserId.equals(that.updateUserId) : that.updateUserId != null) return false;
        if (updateTime != null ? !updateTime.equals(that.updateTime) : that.updateTime != null) return false;
        if (delFlag != null ? !delFlag.equals(that.delFlag) : that.delFlag != null) return false;
        if (entryDate != null ? !entryDate.equals(that.entryDate) : that.entryDate != null) return false;
        if (leaveDate != null ? !leaveDate.equals(that.leaveDate) : that.leaveDate != null) return false;
        if (workContract != null ? !workContract.equals(that.workContract) : that.workContract != null) return false;
        if (workContractStartTime != null ? !workContractStartTime.equals(that.workContractStartTime) : that.workContractStartTime != null)
            return false;
        if (workContractEndTime != null ? !workContractEndTime.equals(that.workContractEndTime) : that.workContractEndTime != null)
            return false;
        if (parentId != null ? !parentId.equals(that.parentId) : that.parentId != null) return false;
        if (email != null ? !email.equals(that.email) : that.email != null) return false;

        return true;
    }

    @Override
    public int hashCode() {
        int result = id != null ? id.hashCode() : 0;
        result = 31 * result + (name != null ? name.hashCode() : 0);
        result = 31 * result + (tel != null ? tel.hashCode() : 0);
        result = 31 * result + (pwd != null ? pwd.hashCode() : 0);
        result = 31 * result + (roleId != null ? roleId.hashCode() : 0);
        result = 31 * result + (createUserId != null ? createUserId.hashCode() : 0);
        result = 31 * result + (createTime != null ? createTime.hashCode() : 0);
        result = 31 * result + (updateUserId != null ? updateUserId.hashCode() : 0);
        result = 31 * result + (updateTime != null ? updateTime.hashCode() : 0);
        result = 31 * result + (delFlag != null ? delFlag.hashCode() : 0);
        result = 31 * result + (entryDate != null ? entryDate.hashCode() : 0);
        result = 31 * result + (leaveDate != null ? leaveDate.hashCode() : 0);
        result = 31 * result + (workContract != null ? workContract.hashCode() : 0);
        result = 31 * result + (workContractStartTime != null ? workContractStartTime.hashCode() : 0);
        result = 31 * result + (workContractEndTime != null ? workContractEndTime.hashCode() : 0);
        result = 31 * result + (parentId != null ? parentId.hashCode() : 0);
        result = 31 * result + (email != null ? email.hashCode() : 0);
        return result;
    }
}
